<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <title>Title</title>
</head>
<body>

<form action="#" method="post">
    <p>
        <span>用户名：</span><input type="text" id="username" name="username">
    </p>

    <p>
        <span>密码：</span><input type="text" id="password" name="password">
    </p>


    <!--绑定事件 onclick 被点击-->
    <button type="button" onclick="aaa()">提交</button>
    
</form>

<script>
    function aaa() {
        var uname = document.getElementById('username');
        var pwd = document.getElementById('password');

        //使用MD5进行加密

    }
</script>

</body>
</html>